<?php
declare(strict_types=1);

use Phinx\Migration\AbstractMigration;

final class ExtendStatusEnumValueInTenantUserTable extends AbstractMigration
{
    public function up()
    {
        $this->table('tenant_user')
            ->changeColumn('status', 'enum', [
                'values' => 'active,invalid,unemployed',
                'default' => 'invalid',
                'comment' => '租户成员状态',
            ])
            ->save();
    }

    public function down()
    {
        $this->table('tenant_user')
            ->changeColumn('status', 'enum', [
                'values' => 'active,invalid',
                'default' => 'invalid',
                'comment' => '租户成员状态',
            ])
            ->save();
    }
}
